﻿<%template _header%>
<%namespace YouHP.Model%>
<%namespace YouHP.BLL%>
<%namespace YouHP.Model.Group%>

<div class="layout-cols2">
	
	<div class="col1">
	    
	    <div class="box">
			<div class="content">
				<div class="news">
				    <h1>{LogTopicData.Title}</h1>
				    <div style="text-align:right">
				        <%csharp%>TempUrl=this.GetUrl("/Profile/Log.aspx?uid=" + UserData.Id + "&id=" + LogTopicData.Id); <%/csharp%>				        
				        &gt;&gt;<a href="{TempUrl}">查看全文</a>
				        <%csharp%>TempUrl=this.GetUrl("/User/LogEdit.aspx?id=" + LogTopicData.Id); <%/csharp%>				        
				        &nbsp;&nbsp;&gt;&gt;<a href="{TempUrl}">编辑</a>
				    </div>
				</div>
			</div>
		</div>
	    
	    <div class="box">
	    <div class="pl">
		    <div class="pl_title">
		        <span>评论总数：<b><font name="fedcount" id="fedcount">{DataCount}</font> </b>条 
		        </span>
		        网友评论
		    </div>
		    <span name="fedbk" id="fedbk">
		        
                <ul class="hugbook">
                    
	                <%csharp%>
	                    int floor = DataCount;
	                    foreach(LogReplyInfo item in ReplyDataList) { 
		            <%/csharp%>
		            
	                <li>
	                    <div style="padding-left:20px; text-align:center; float:left;">
	                    <%csharp%>TempUrl = "/Profile/Index.aspx?uid=" + item.PostUserId;<%/csharp%>
	                    <a href="{this.GetUrl(TempUrl)}">
                            <img class="avatar" width="40" src="{UserBLL.Instance.GetUserInfo(item.PostUserId).Avatar}"/>
                        </a>
                        </div>
                        <div style="margin:0pt 10px 0pt 82px;">
                            <p class="graytext">
                                <span style="float:right;">
                                    
                                    <%csharp%>if(item.PostUserId == UserData.Id) { <%/csharp%>
		                            <%csharp%> TempUrl = "/User/LogReplyEdit.aspx?tid=" + LogTopicData.Id + "&id=" + item.Id; <%/csharp%>
		                            <a href="{this.GetUrl(TempUrl)}">编辑</a>&nbsp;&nbsp;&nbsp;&nbsp;
		                            <%csharp%> }  <%/csharp%>
		                    
        		                    <%csharp%> TempUrl = "/User/LogReplyDel.aspx?tid=" + LogTopicData.Id + "&id=" + item.Id; <%/csharp%>
		                            <a href="{this.GetUrl(TempUrl)}">删除</a>&nbsp;&nbsp;&nbsp;&nbsp;
		                            
                                    第 {floor} 楼
                                    
                                </span>
                                <%csharp%>TempUrl = "/Profile/Index.aspx?uid=" + item.PostUserId;<%/csharp%>
                                <a class="client_name" href="{this.GetUrl(TempUrl)}">{item.PostUserName}</a>
                                <%csharp%>TempUrl = item.PostTime.ToString("yyyy-MM-dd  hh:mm");<%/csharp%>
                                {TempUrl}
                            </p>
                            <p class="longtextfix"> {item.Body} </p>
                        </div>
                        <div style="clear: both;"/>
	                </li>
	                
		            <%csharp%>
		                floor --;
		            }
		            <%/csharp%>
		            
	            </ul>

		    </span>

	    </div>     
	    </div>
	    
	    <div class="box">
			<div class="content">
				<div class="pages">
					{PagingString}
				</div>
			</div>
		</div>
	    
	    
	    <script type="text/javascript">
		    function SubmitReplyForm()
		    {
		        var msg = document.feedback.msg.value.trim();
		        if (msg.length == 0)
                {
                    alert("评论内容不能为空！");
                    return;
                }
                else
                {
                    _$('feedback').submit();
                }
		    }
		</script>
		
	    <div class="box">
	        <div class="caption">
	            发表评论：
	        </div>
	        <div class="content">
	            <%csharp%>TempUrl = "/Profile/LogReplyAdd.aspx?uid=" + UserData.Id + "&id=" + LogTopicData.Id; <%/csharp%>
    	        <form id="feedback" name="feedback" method="post" action="{this.GetUrl(TempUrl)}">
	                <div id="plshow">
	                    <div class="bor"> 
                            <textarea name="msg" cols="110" rows="6" id="msg" class="rev_textarea"></textarea>
                        </div>
                        &nbsp;&nbsp;请文明参与讨论，禁止漫骂攻击。
                        <input name="sb" type="button" value="马上发表" class="btn" onClick='SubmitReplyForm();' />
                    </div>
                 </form>
            </div>
	    </div>
	           
	</div> <!-- <div class="col1"> -->	

	
	<div class="col2">
		<%template _Menu%>
	</div>
	
</div>

<%template _footer%>		
